package net.xiduth.game.player.dialogues.auto;

import net.xiduth.game.player.dialogues.Dialogue;
import net.xiduth.utils.ShopsHandler;

public class DonatorShops extends Dialogue {

	@Override
	public void start() {
		sendOptionsDialogue("Choose a shop",
				"Shop 1 - Premium Store",
				"Shop 2 - Premium Apparel",
				"Shop 3 - Premium Gear",
				"Shop 4 - Extreme Donator Pet Shop");
		stage = 2;
	}

	@Override
	@SuppressWarnings("unused")
	public void run(int interfaceId, int componentId) {
		int option;
		if (stage == 2) {
			if (componentId == OPTION_1) {
				ShopsHandler.openShop(player, 50);
				end();
			}
			if (componentId == OPTION_2) {
				ShopsHandler.openShop(player, 200);
				end();
			}
			if (componentId == OPTION_3) {
				ShopsHandler.openShop(player, 1324);
				end();
			}
			if(componentId == OPTION_4){
				if(player.isExtremeDonator() || player.isVIPDonator()){
				ShopsHandler.openShop(player, 55);
				end();
				}else {
					player.sm("You need to be an Extreme Donator or VIP to look in this shop");
					end();
				}
			}
		}
		if (stage == -2) {
			end();
		}
	}

	@Override
	public void finish() {

	}

}